package com.github.freegeese.maven.plugin.autocode.configuration;

import org.apache.commons.lang3.builder.ToStringBuilder;

import java.util.Map;

/**
 * Created by Administrator on 2017/3/31.
 */
public class Template {
    // 模板文件名称
    private String name;
    // 模板参数
    private Map<String, Object> parameterMap;
    // 输出路径
    private String outputPath;
    // 如果输出文件已存在，是否覆盖
    private boolean override;
    // 自定义代码开始标记
    private String customCodeStart;
    // 自定义代码结束标记
    private String customCodeEnd;

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Map<String, Object> getParameterMap() {
        return parameterMap;
    }

    public void setParameterMap(Map<String, Object> parameterMap) {
        this.parameterMap = parameterMap;
    }

    public String getOutputPath() {
        return outputPath;
    }

    public void setOutputPath(String outputPath) {
        this.outputPath = outputPath;
    }

    public boolean isOverride() {
        return override;
    }

    public void setOverride(boolean override) {
        this.override = override;
    }

    public String getCustomCodeStart() {
        return customCodeStart;
    }

    public void setCustomCodeStart(String customCodeStart) {
        this.customCodeStart = customCodeStart;
    }

    public String getCustomCodeEnd() {
        return customCodeEnd;
    }

    public void setCustomCodeEnd(String customCodeEnd) {
        this.customCodeEnd = customCodeEnd;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this)
                .append("name", name)
                .append("parameterMap", parameterMap)
                .append("outputPath", outputPath)
                .append("override", override)
                .toString();
    }
}
